import pandas as pd
pd.set_option('display.unicode.east_asian_width', True)
df = pd.read_excel('student_info.xlsx', index_col=0)
print(df)
df['体质指数'] = df['体重（kg）'] / (df['身高（m）'] ** 2)
df['健身状况'] = pd.cut(df['体质指数'], bins=[0, 18.5, 24, 28, 50], right=False, include_lowest=True, labels=['1', '2', '3', '4'])
print(df)
print(pd.get_dummies(df, prefix='', prefix_sep='', columns=['性别']))